package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

@Data
@ApiModel(value = "销售车")
@TableName("t_sale_cart")
public class SaleCartBean {
    @ApiModelProperty(hidden = true)
    @TableId(value = "pk_saleId",type = IdType.AUTO)
    private Integer id;
    @ApiModelProperty(value = "销售价")
    @TableField("s_salenum")
    private Integer saleNum;
    @ApiModelProperty(value = "销售员ID")
    @TableField("fk_userId")
    private Integer userId;
    @ApiModelProperty(value = "库存商品ID")
    @TableField("fk_shopId")
    private String stockShopId;

    @TableField(exist = false)
    private StockShopBean stockShop;

    public SaleCartBean() {
    }

    public SaleCartBean(Integer saleNum, Integer userId, String stockShopId) {
        this.saleNum = saleNum;
        this.userId = userId;
        this.stockShopId = stockShopId;
    }

    public SaleCartBean(Integer saleNum, Integer userId, String stockShopId, StockShopBean stockShop) {
        this.saleNum = saleNum;
        this.userId = userId;
        this.stockShopId = stockShopId;
        this.stockShop = stockShop;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getSaleNum() {
        return saleNum;
    }

    public void setSaleNum(Integer saleNum) {
        this.saleNum = saleNum;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getStockShopId() {
        return stockShopId;
    }

    public void setStockShopId(String stockShopId) {
        this.stockShopId = stockShopId;
    }

    public StockShopBean getStockShop() {
        return stockShop;
    }

    public void setStockShop(StockShopBean stockShop) {
        this.stockShop = stockShop;
    }

    @Override
    public String toString() {
        return "SaleCartBean{" +
                "id=" + id +
                ", saleNum=" + saleNum +
                ", userId=" + userId +
                ", stockShopId=" + stockShopId +
                ", stockShop=" + stockShop +
                '}';
    }
}
